<?php 
/****
布尔教育 高端PHP培训
培  训: http://www.itbool.com
论  坛: http://www.zixue.it
****/

$con = mysqli_connect('localhost' , 'root' , '' , '170514php');
mysqli_set_charset($con,'utf8');

//select
$sql = "select * from msg";
$rs = mysqli_query($con, $sql);
/*print_r(mysqli_fetch_assoc($rs));
print_r(mysqli_fetch_assoc($rs));
print_r(mysqli_fetch_assoc($rs));
print_r(mysqli_fetch_assoc($rs));*/
print_r(mysqli_fetch_assoc($rs));
print_r(mysqli_fetch_array($rs));
print_r(mysqli_fetch_row($rs));

?>